#pragma once
#include <Theron/Theron.h>
#include <Singleton.h>

//class CThreadB : public Theron::Actor, public Singleton<CThreadB>
class CThreadB : public Theron::Actor
{
public:
    int m_id;
    Theron::Framework t_framwork;
    //friend class Singleton<CThreadB>;
    CThreadB() : Theron::Actor(t_framwork) {

    }
    CThreadB(Theron::Framework &framwork) : Theron::Actor(framwork)
    {
        //×¢²áÏûÏ¢º¯Êý
        RegisterHandler(this, &CThreadB::handleInt);
    }

    int setID(int id);
    int getID();
    void handleInt(const int& item, const Theron::Address from);
    int send2ThreadbyID(int data, int ID);
};